<nav class="text-right" aria-label="Page navigation">
    <ul class="pagination" *ngIf="page.showPages.length > 0">
        <li [ngClass]="{disabled:page.currentPage == 0}">
            <a (click)="pageSelectClick(page.currentPage == 0 ? 0:page.currentPage - 1)" aria-label="Previous">
                <span aria-hidden="true">&laquo;</span>
            </a>
        </li>
        <li *ngFor="let showPage of page.showPages" [ngClass]="{active:page.currentPage == showPage}"><a (click)="pageSelectClick(showPage)">{{showPage + 1}}</a></li>
        <li [ngClass]="{disabled:page.currentPage == page.totalPage-1}">
            <a (click)="pageSelectClick(page.currentPage == page.totalPage-1 ? page.totalPage-1:page.currentPage + 1)" aria-label="Next">
                <span aria-hidden="true">&raquo;</span>
            </a>
        </li>
    </ul>
</nav>